package edu.whu.demo.service;

import com.baomidou.mybatisplus.core.metadata.IPage;
import edu.whu.demo.domain.Activity;
import com.baomidou.mybatisplus.extension.service.IService;
import edu.whu.demo.exception.ActivityAdminException;
import edu.whu.demo.exception.MessageException;

import java.util.Map;

/**
 * <p>
 *  服务类
 * </p>
 *
 * @author 
 * @since 2022-11-24
 */
public interface IActivityService extends IService<Activity> {

    //实现整个活动的添加，包括abstract和detail
    Activity addActivity(Activity activity);
    //实现整个活动的更新，包括abstract和detail
    void updateActivity(Long id, Activity activity) throws ActivityAdminException;

    void deleteActivity(Long id) throws ActivityAdminException;

    IPage<Activity> findActivity(Map<String,Object> conditions, Integer pageNum, Integer pageSize);

    //审核活动
    void verifyActivity(Long id, Boolean verify) throws ActivityAdminException, MessageException;

}
